<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <th:block th:insert="~{fragments/template::css}"></th:block>
</head>
<body>
<div id="app">
    <h1>这是主页index.html</h1>
    <p>{{ count }}</p>
    <el-button @click="increment">点击++</el-button>
</div>

<div th:insert="~{fragments/template::test}">
    test
</div>

<th:block th:insert="~{fragments/template::js}"></th:block>
<script>
    Vue.createApp({
        data() {
            return {
                count: 0,
            }
        },
        methods: {
            increment() {
                this.count ++
            },
        },
    }).use(ElementPlus).mount('#app')
</script>
</body>
</html>